package org.mycub.server.dataprovider;

import java.util.List;

import org.mycub.server.data.models.VCUBStation;
import org.mycub.server.mongodb.MongoDB;

public class VCUBStationsProvider {

	/**
	 * @param args
	 */
	private List<VCUBStation> stations;
	
	public List<VCUBStation> getVCUBs(double longitude, double latitude, double rayon){
		
		List<VCUBStation> vCUBStations = MongoDB.dataStore.find(VCUBStation.class).
				field("location").within(longitude,latitude,rayon).asList();
		
		return vCUBStations;
	}

	public List<VCUBStation> getStations() {
		return stations;
	}

	public void setStations(List<VCUBStation> stations) {
		this.stations = stations;
	}

}
